/*
 * Package: org.grassfield.common.service
 * FileName: IUserService.java
 *  
 * Created by pandian on Jan 28, 2011
 */
package service;

import java.util.List;
import java.util.Set;
import bean.User;


/**
 * The Interface IUserService.
 */
public interface IUserService {
	
	/**
	 * List.
	 * 
	 * @return the list
	 */
	public List<User> list();
	
	/**
	 * Gets the user.
	 * 
	 * @param userName the user name
	 * @param password the password
	 * @return the user
	 */
	public User getUser(String userName, String password);
	
	/**
	 * Gets the user.
	 * 
	 * @param id the id
	 * @return the user
	 */
	public User getUser(long id);

	/**
	 * Adds the user.
	 * 
	 * @param newUser the new user
	 * @return the user
	 */
	public User addUser(User newUser);

	/**
	 * Gets the id ary to set.
	 * 
	 * @param userIdAry
	 *            the user id ary
	 * @return the id ary to set
	 */
	Set<User> getIdAryToSet(Long[] userIdAry);

	/**
	 * Gets the ary to user set.
	 * 
	 * @param userList
	 *            the user list
	 * @return the ary to user set
	 */
	Long[] getAryToUserSet(Set<User> userList);

}
